#include <stdio.h>

double avg(int length, double array[length]);
double max(int rows, int cols, double array[][cols]);

int main(void)
{
	double array[3][5];

	int i;

	scanf("%d",array[0]);
	printf("%.2f", array[0][0]);
	for(i = 0; i < 3; i++)
	{
		printf("请输入第%d组数:", i + 1);
		scanf("%.2f %.2f %.2f %.2f %.2f", array[i], array[i] + 1,
			array[i] + 2, array[i]+ 3, array[i] + 4);
		printf("%.2f %.2f %.2f %.2f %.2f",*(array[i]), *(array[i] + 1),
			*(array[i] + 2), *(array[i]+ 3), *(array[i] + 4));
	}
	return 0;
}
double avg(int length, double array[length])
{
	int i;
	double avg,total;

	for(i = 0, total = 0; i < length; i++)
	{
		total += array[i];
	}
	avg = total / length;
	
	return avg;
	
}

double max(int rows, int cols, double array[][cols])
{
	int i,j;
	double max;

	for(i = 0; i < rows; i++)
	{
		for(j = 0, max = array[0][0]; j < cols; j++)
		{
			if( array[i][j] > max)
				max = array[i][j];	
		} 
	}
	
	return max;
}

